package com.jdrx.sw.sewage.beans.dto;

import java.time.LocalDateTime;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

import org.springframework.format.annotation.DateTimeFormat;

import com.fasterxml.jackson.annotation.JsonFormat;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

@ApiModel(value = "新增药剂分析参数", description = "新增药剂分析参数")
@Data
public class MedicineAnalysisAddDTO {
	@NotBlank
	@ApiModelProperty(value = "药剂类型", required = true)
	private String categoryName;
	
	@ApiModelProperty(value = "关联点位，取自药剂类型关联点位")
	private String devPointValue;
	
	@ApiModelProperty(value = "加药时间")
	@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
	@DateTimeFormat(iso = DateTimeFormat.ISO.DATE_TIME, pattern = "yyyy-MM-dd HH:mm:ss")
	private LocalDateTime addTime;
	
	@NotNull
	@ApiModelProperty(value = "加药数量", required = true)
	private Double amount;
	
	@NotNull
	@ApiModelProperty(value = "药剂单价", required = true)
	private Double price;
	
	@ApiModelProperty(value = "记录员", hidden = true)
	private Long noteTaker;
	
	@ApiModelProperty(hidden = true)
	@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
	@DateTimeFormat(iso = DateTimeFormat.ISO.DATE_TIME, pattern = "yyyy-MM-dd HH:mm:ss")
	private LocalDateTime createAt = LocalDateTime.now();
	
	@ApiModelProperty(hidden = true)
	private Long createBy;
}